package org.yscz.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.ToString;
import lombok.experimental.Accessors;

import javax.validation.constraints.NotEmpty;
import java.io.Serializable;
import java.util.Date;

/**
 * @program: pe
 * @description: 项目表
 * @author: muqs
 * @create: 2021-08-18 21:12
 **/
@Data
@ToString
@Accessors(chain = true)
@TableName(value = "t_project")
public class Project implements Serializable {

    /**
     * 项目ID
     */
    @TableId(value = "project_id", type = IdType.AUTO)
    private Long projectId;

    /**
     * 项目名称
     */
    @NotEmpty(message = "请选择行业配置")
    @TableField(value = "project_name")
    private String projectName;

    /**
     * 登录与引导页
     */
    @NotEmpty(message = "请选择页面样式")
    @TableField(value = "guide_pages")
    private String guidePages;

    /**
     * 公司名称
     */
    @NotEmpty(message = "请输入公司名称")
    @TableField(value = "company_name")
    private String companyName;

    /**
     * 电话号码
     */
    @NotEmpty(message = "请输入电话号码")
    @TableField(value = "phone")
    private String phone;

    /**
     * 系统名称
     */
    @NotEmpty(message = "请输入系统名称")
    @TableField(value = "system_name")
    private String systemName;

    /**
     * 项目描述
     */
    @TableField(value = "project_content")
    private String projectContent;

    /**
     * 时长上限
     */
    @NotEmpty(message = "请输入时长上限")
    @TableField(value = "time_up")
    private Integer timeUp;

    /**
     * 时长下限
     */
    @NotEmpty(message = "请输入时长下限")
    @TableField(value = "time_down")
    private Integer timeDown;

    /**
     * 创建时间
     */
    @TableField(value = "create_time")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "Asia/Shanghai")
    private Date createTime;

    /**
     * 更新时间
     */
    @TableField(value = "update_time")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "Asia/Shanghai")
    private Date updateTime;

    /**
     * 系统版本号
     */
    @TableField(value = "project_version")
    private String projectVersion;

    /**
     * 项目类别ID
     */
    @TableField(value = "project_type_id_fk")
    private Long projectTypeIdFk;
}
